Skip to content

Improve add reliability: recovery, cancel, and downloads - #7

Merged
Graphixa merged 23 commits into
mainfrom
optimization-refactor
Sep 18, 2026
Merged

Graphixa merged 23 commits into
mainfrom
optimization-refactor

Conversation

@Graphixa

Copy link
Copy Markdown
Owner

Summary

  • Harden fontget add per the reliability spec: correct failure exits, noninteractive progress, isolated staging, package rollback with safe --force, smarter download fallback, cancellable external tools, and consistent checksums.
  • Address senior review on 702f3b1: registration-aware rollback, unique install artifacts + collision checks, progress-worker join on cancel, bounded process/pipe teardown, timed error-body drain, rate-limit no longer advances candidates, structured HTTP status from wget/PowerShell.
  • Also wires extract cancellation context, uses recovery timeout during rollback, and locks destinations during remove.

Test plan

  • CI Windows + Linux green on this PR
  • Re-review seven high/medium findings against 9193bad
  • Smoke: fontget add <id> --force (multi-file package) and cancel during download/install
  • Confirm failed partial install restores files/registrations or retains recovery record

Make package outcomes drive non-zero exits, isolate staging, roll back partial installs with safe force replace, and classify downloads with cancellable external tools and consistent checksums.
Make package rollback registration-aware, use unique install artifacts, join progress workers on every exit, bound external-process teardown, time-limit error-body drains, and keep rate-limits from advancing candidates.
staticcheck U1000 failed CI on logInstallResultDetails, updateInstallStatus, and installFontsInDebugMode.
… error handling

- Removed unused dependency on github.com/blang/semver and updated to use golang.org/x/mod v0.41.0.
- Refactored font installation tests to utilize a new control structure for injecting failure scenarios, enhancing test reliability and clarity.
- Simplified table rendering in various commands by using default column configurations.
- Removed deprecated functions and cleaned up code for better maintainability.
…ion handling and track incomplete operations
…tion for tracked files and better cancellation handling. Also Fixed error reporting during removal operations.
Without the deleted cross-platform tests, ubuntu staticcheck flags the helpers as unused (U1000).
@Graphixa
Graphixa merged commit b4e6e4f into main Sep 18, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant